package tk.uodrad.apex.project.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import tk.uodrad.apex.project.pojo.dto.PeopleAddNewDTO;
import tk.uodrad.apex.project.pojo.dto.PeopleUpdateDTO;
import tk.uodrad.apex.project.pojo.entity.People;
import com.baomidou.mybatisplus.extension.service.IService;
import tk.uodrad.apex.project.pojo.vo.PeopleListVO;

/**
* @author Administrator
* @description 针对表【people_management】的数据库操作Service
* @createDate 2023-03-23 19:57:33
*/
public interface PeopleService extends IService<People> {
    /**
     * 添加单个成员
     * @param peopleAddNewDTO 添加成员DTO
     */
    void save(PeopleAddNewDTO peopleAddNewDTO);

    /**
     * 根据ID修改成员
     * @param peopleUpdateDTO 修改成员DTO
     */
    void updateById(PeopleUpdateDTO peopleUpdateDTO);

    /**
     * 分页查询成员列表
     * @param pageNum 第几页
     * @param pageSize 每页多少条数据
     * @param communityCode 小区编号
     * @return IPage<PeopleListVO> PeopleListVO分页对象
     */
    IPage<PeopleListVO> list(Integer pageNum, Integer pageSize, String communityCode);

    /*
    * 统计人数
    * */
    Integer countPeople();
}
